load(":defs.bzl", "create_test_img")

package(default_visibility = ["__subpackages__"])

exports_files([
    "partitions.csv",
    "grub.cfg",
    "config/config.ini",
    "config/node_operator_private_key.pem",
    "config/ssh_authorized_keys/admin",
    "data/deployment.json.template",
    "data/nns_public_key_override.pem",
])

# All setup-os targets are named the same, just stay in different submodules.
# To build or run specific target:
#
# bazel run   //ic-os/setupos/envs/prod:upload_disk-img           [--s3_endpoint=<internal endpoint address>]
# bazel build //ic-os/setupos/envs/dev/...
#
# check //ic-os/defs.bzl for the full list of targets.

# Postprocess SetupOS dev into a "test" image for use in nested tests
create_test_img(
    name = "test-img",
    source = "//ic-os/setupos/envs/dev:disk-img.tar.zst",
    tags = [
        "manual",
        "no-cache",
    ],
    visibility =
        [
            "//rs:ic-os-pkg",
            "//rs:system-tests-pkg",
        ],
)

# Postprocess SetupOS mainnet into a "test" image for use in nested tests
create_test_img(
    name = "mainnet-latest-test-img",
    compat = True,
    source = "@mainnet_latest_hostos_images//:disk-img.tar.zst",
    tags = [
        "manual",
        "no-cache",
    ],
    visibility = [
        "//rs:ic-os-pkg",
        "//rs:system-tests-pkg",
    ],
)

# Postprocess SetupOS mainnet dev into a "test" image for use in nested tests
create_test_img(
    name = "mainnet-latest-test-img-dev",
    compat = True,
    source = "@mainnet_latest_hostos_images_dev//:disk-img.tar.zst",
    tags = [
        "manual",
        "no-cache",
    ],
    visibility = [
        "//rs:ic-os-pkg",
        "//rs:system-tests-pkg",
    ],
)
